#ifndef RECORD_ALARM_H
#define RECORD_ALARM_H
#include "rfidlib.h"
#include "string.h"

//Used By LSG Control Center
class CRecord_Alarm
{
public:
    BYTE sid = 0;
    BYTE eventtype = 0;
    BYTE uid[64];
    DWORD uidLen = 64;
    BYTE user[1024];
    DWORD userLen = 1024;
    BYTE dFlag = 0;
    BYTE date[7];

public:
    CRecord_Alarm &operator=(const CRecord_Alarm &src)
    {
        sid = src.sid;
        eventtype= src.eventtype;
        dFlag = src.dFlag;
        if(src.uidLen>0)
            memcpy(uid,src.uid,uidLen);

        if(src.userLen>0)
            memcpy(user,src.user,userLen);

        memcpy(date,src.date,7);

        return *this;
    }
};
#endif // CRECORD_ALARM_H
